#!/bin/sh
#Make sure you have installed x11/kdelibs4 the same version as kde4-l10n ports.
. $area51/Tools/scripts/mkplist/settings.conf

export PREFIX=${WORKDIR}/kde4-l10n/install
export WRKDIRPREFIX=${WORKDIR}/kde4-l10n/wrkdir
export PKG_DBDIR=${WORKDIR}/kde4-l10n/vardbpkg

if [ -d ${WORKDIR}/kdehier4 ]; then
	rm -rf ${WORKDIR}/kde4-l10n
fi

for p in ${KDE4_L10N_PORTS}; do
	mkdir -p ${PREFIX}; mkdir -p ${WRKDIRPREFIX}; mkdir -p ${PKG_DBDIR}
	cd ${KDE4_L10N_PORTSTREE}/$p
	make clean makesum
	make install clean -DINSTALL_AS_USER -DNO_DEPENDS -DBATCH PREFIX=${PREFIX} > /dev/null
	$area51/Tools/scripts/mkplist/make_plist ${PREFIX}
	rm -rf ${WORKDIR}/kde4-l10n
done
